gusucode.com > ​数字信号处理,包括:各种现有信号及随机信号的输入,从文件读取数据的输入 > Digital Signal Matlab ex1/DigitalSignalOne.m

    function varargout = DigitalSignalOne(varargin)
% DIGITALSIGNALONE M-file for DigitalSignalOne.fig
%      DIGITALSIGNALONE, by itself, creates a new DIGITALSIGNALONE or raises the existing
%      singleton*.
%
%      H = DIGITALSIGNALONE returns the handle to a new DIGITALSIGNALONE or the handle to
%      the existing singleton*.
%
%      DIGITALSIGNALONE('CALLBACK',hObject,eventData,handles,...) calls the local
%      function named CALLBACK in DIGITALSIGNALONE.M with the given input arguments.
%
%      DIGITALSIGNALONE('Property','Value',...) creates a new DIGITALSIGNALONE or raises the
%      existing singleton*.  Starting from the left, property value pairs are
%      applied to the GUI before DigitalSignalOne_OpeningFunction gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to DigitalSignalOne_OpeningFcn via varargin.
%
%      *See GUI Options on GUIDE's Tools menu.  Choose "GUI allows only one
%      instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES

% Copyright 2002-2003 The MathWorks, Inc.

% Edit the above text to modify the response to help DigitalSignalOne

% Last Modified by GUIDE v2.5 27-Apr-2009 17:51:33

% Begin initialization code - DO NOT EDIT

gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @DigitalSignalOne_OpeningFcn, ...
                   'gui_OutputFcn',  @DigitalSignalOne_OutputFcn, ...
                   'gui_LayoutFcn',  [] , ...
                   'gui_Callback',   []);
if nargin && ischar(varargin{1})
    gui_State.gui_Callback = str2func(varargin{1});
end

if nargout
    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
    gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT

% --- Executes just before DigitalSignalOne is made visible.
function DigitalSignalOne_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
% varargin   command line arguments to DigitalSignalOne (see VARARGIN)

% Choose default command line output for DigitalSignalOne
handles.output = hObject;

% Update handles structure
guidata(hObject, handles);

% This sets up the initial plot - only do when we are invisible
% so window can get raised using DigitalSignalOne.
if strcmp(get(hObject,'Visible'),'off')
    plot(rand(5));
end

% UIWAIT makes DigitalSignalOne wait for user response (see UIRESUME)
% uiwait(handles.figure1);


% --- Outputs from this function are returned to the command line.
function varargout = DigitalSignalOne_OutputFcn(hObject, eventdata, handles)
% varargout  cell array for returning output args (see VARARGOUT);
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure
varargout{1} = handles.output;

% --- Executes on button press in pushbutton1.
function pushbutton1_Callback(hObject, eventdata, handles)
% hObject    handle to pushbutton1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
axes(handles.axes1);
cla;

popup_sel_index = get(handles.popupmenu1, 'Value');
switch popup_sel_index
    case 1
        plot(rand(5));
    case 2
        plot(sin(1:0.01:25.99));
    case 3
        bar(1:.5:10);
    case 4
        plot(membrane);
    case 5
        surf(peaks);
end


% --------------------------------------------------------------------
function FileMenu_Callback(hObject, eventdata, handles)
% hObject    handle to FileMenu (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function OpenMenuItem_Callback(hObject, eventdata, handles)
% hObject    handle to OpenMenuItem (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
file = uigetfile('*.fig');
if ~isequal(file, 0)
    open(file);
end

% --------------------------------------------------------------------
function PrintMenuItem_Callback(hObject, eventdata, handles)
% hObject    handle to PrintMenuItem (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
printdlg(handles.figure1)

% --------------------------------------------------------------------
function CloseMenuItem_Callback(hObject, eventdata, handles)
% hObject    handle to CloseMenuItem (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
selection = questdlg(['Close ' get(handles.figure1,'Name') '?'],...
                     ['Close ' get(handles.figure1,'Name') '...'],...
                     'Yes','No','Yes');
if strcmp(selection,'No')
    return;
end

delete(handles.figure1)


% --- Executes on selection change in popupmenu1.
function popupmenu1_Callback(hObject, eventdata, handles)
% hObject    handle to popupmenu1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: contents = get(hObject,'String') returns popupmenu1 contents as cell array
%        contents{get(hObject,'Value')} returns selected item from popupmenu1


% --- Executes during object creation, after setting all properties.
function popupmenu1_CreateFcn(hObject, eventdata, handles)
% hObject    handle to popupmenu1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: popupmenu controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc
    set(hObject,'BackgroundColor','white');
else
    set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));
end

set(hObject, 'String', {'plot(rand(5))', 'plot(sin(1:0.01:25))', 'bar(1:.5:10)', 'plot(membrane)', 'surf(peaks)'});



% --------------------------------------------------------------------
function StandardSignal_Callback(hObject, eventdata, handles)
% hObject    handle to StandardSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function Signal_Callback(hObject, eventdata, handles)
% hObject    handle to Signal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function UnitImpulseList_Callback(hObject, eventdata, handles)
% hObject    handle to UnitImpulseList (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
UnitImpulseList()

% --------------------------------------------------------------------
function PBlackman_Callback(hObject, eventdata, handles)
% hObject    handle to PBlackman (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
PBlackman()

% --------------------------------------------------------------------
function UnitStepSeries_Callback(hObject, eventdata, handles)
% hObject    handle to UnitStepSeries (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
UnitStepSeries()

% --------------------------------------------------------------------
function RectangleSeries_Callback(hObject, eventdata, handles)
% hObject    handle to RectangleSeries (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
RectangleSeries()

% --------------------------------------------------------------------
%function SinList_Callback(hObject, eventdata, handles)
% hObject    handle to SinList (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
%SinList()



% --------------------------------------------------------------------
function fft_Callback(hObject, eventdata, handles)
% hObject    handle to fft (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function transformation_Callback(hObject, eventdata, handles)
% hObject    handle to transformation (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)




% --------------------------------------------------------------------
function FFT_Callback(hObject, eventdata, handles)
% hObject    handle to FFT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
FFT()



% --------------------------------------------------------------------
%function text_Callback(hObject, eventdata, handles)
% hObject    handle to text (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
%text()



% --------------------------------------------------------------------
function IFFT_Callback(hObject, eventdata, handles)
% hObject    handle to IFFT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
IFFT()



% --------------------------------------------------------------------
function DCT_Callback(hObject, eventdata, handles)
% hObject    handle to DCT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
DCT()



% --------------------------------------------------------------------
function IDCT_Callback(hObject, eventdata, handles)
% hObject    handle to IDCT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
IDCT()



% --------------------------------------------------------------------
function HILBERT_Callback(hObject, eventdata, handles)
% hObject    handle to HILBERT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
HILBERT()



% --------------------------------------------------------------------
function czt_Callback(hObject, eventdata, handles)
% hObject    handle to czt (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function CZT_Callback(hObject, eventdata, handles)
% hObject    handle to CZT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
CZT()



% --------------------------------------------------------------------
function filter_Callback(hObject, eventdata, handles)
% hObject    handle to filter (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)




% --------------------------------------------------------------------
function Butterworth_Callback(hObject, eventdata, handles)
% hObject    handle to Butterworth (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
Butterworth()



% --------------------------------------------------------------------
function BackTran_Callback(hObject, eventdata, handles)
% hObject    handle to BackTran (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
%function Chebyshev1_Callback(hObject, eventdata, handles)
% hObject    handle to Chebyshev1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
%Chebyshev1()



% --------------------------------------------------------------------
function Cherbyshev1_Callback(hObject, eventdata, handles)
% hObject    handle to Cherbyshev1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
Chebyshev1()



% --------------------------------------------------------------------
function Cherbyshev2_Callback(hObject, eventdata, handles)
% hObject    handle to Cherbyshev2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
Cherbyshev2()



% --------------------------------------------------------------------
function Ellipap_Callback(hObject, eventdata, handles)
% hObject    handle to Ellipap (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
Ellipap()



% --------------------------------------------------------------------
function besselap_Callback(hObject, eventdata, handles)
% hObject    handle to besselap (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function Besselap_Callback(hObject, eventdata, handles)
% hObject    handle to Besselap (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
Besselap()



% --------------------------------------------------------------------
function SignalNoise_Callback(hObject, eventdata, handles)
% hObject    handle to SignalNoise (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
SignalNoise()



% --------------------------------------------------------------------
function PSD_Callback(hObject, eventdata, handles)
% hObject    handle to PSD (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function Peridogram_Callback(hObject, eventdata, handles)
% hObject    handle to Peridogram (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
%Peridogram()






% --------------------------------------------------------------------
function SinCosSignal_Callback(hObject, eventdata, handles)
% hObject    handle to SinCosSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
set(handles.PanelSC,'Visible','off');
set(handles.PanelLineSignal,'Visible','on');
SinCosSignal()



% --------------------------------------------------------------------
%function LineSignal_Callback(hObject, eventdata, handles)
% hObject    handle to LineSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
%LineSignal()



% --------------------------------------------------------------------
function LineSignal_Callback(hObject, eventdata, handles)
% hObject    handle to LineSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
set(handles.PanelLineSignal,'Visible','off')
set(handles.PanelSC,'Visible','on')
LineSignal()



% --------------------------------------------------------------------
function RealExpSeries_Callback(hObject, eventdata, handles)
% hObject    handle to RealExpSeries (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
RealExpSeries()

% --------------------------------------------------------------------
function ComplexExpSeries_Callback(hObject, eventdata, handles)
% hObject    handle to ComplexExpSeries (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
ComplexExpSeries()



% --- Executes on selection change in PStandardSignal.
function PStandardSignal_Callback(hObject, eventdata, handles)
% hObject    handle to PStandardSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: contents = get(hObject,'String') returns PStandardSignal contents as cell array
%        contents{get(hObject,'Value')} returns selected item from PStandardSignal
val=get(hObject,'Value');
str=get(hObject,'String');
switch str{val};
    case '单位冲激序列'
        set(handles.SignalName,'String','单位冲激序列')
        UnitImpulseList()
    case '单位阶跃序列'
        UnitStepSeries()
    case '矩形序列'
        RectangleSeries()
    case '实指数序列'
        RealExpSeries()
    case '复指数序列'
        ComplexExpSeries()
    case '噪声信号'
        SignalNoise();
end
guidata(hObject,handles)

% --- Executes during object creation, after setting all properties.
function PStandardSignal_CreateFcn(hObject, eventdata, handles)
% hObject    handle to PStandardSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: popupmenu controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



% --------------------------------------------------------------------
function PInputSignal_Callback(hObject, eventdata, handles)
% hObject    handle to PInputSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

val=get(hObject,'Value');
str=get(hObject,'String');
switch str{val}
    case 'y=Asin(w1*t)+Bcos(w2*t)+w0'
        set(handles.PanelLineSignal,'Visible','off');
        set(handles.PanelSC,'Visible','on');
        
    case 'y=a(x.^n)+b'
        set(handles.PanelSC,'Visible','off');
        set(handles.PanelLineSignal,'Visible','on');
       
end
guidata(hObject,handles)






% --- Executes during object creation, after setting all properties.
function PInputSignal_CreateFcn(hObject, eventdata, handles)
% hObject    handle to PInputSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: popupmenu controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end





function EditLS_a_Callback(hObject, eventdata, handles)
% hObject    handle to EditLS_a (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditLS_a as text
%        str2double(get(hObject,'String')) returns contents of EditLS_a as a double


% --- Executes during object creation, after setting all properties.
function EditLS_a_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditLS_a (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditLS_n_Callback(hObject, eventdata, handles)
% hObject    handle to EditLS_n (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditLS_n as text
%        str2double(get(hObject,'String')) returns contents of EditLS_n as a double


% --- Executes during object creation, after setting all properties.
function EditLS_n_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditLS_n (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditLS_b_Callback(hObject, eventdata, handles)
% hObject    handle to EditLS_b (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditLS_b as text
%        str2double(get(hObject,'String')) returns contents of EditLS_b as a double


% --- Executes during object creation, after setting all properties.
function EditLS_b_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditLS_b (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


% --- Executes on button press in ButtonLS.
function ButtonLS_Callback(hObject, eventdata, handles)
% hObject    handle to ButtonLS (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
 LineSignal()





function EditSC_A_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_A (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_A as text
%        str2double(get(hObject,'String')) returns contents of EditSC_A as a double


% --- Executes during object creation, after setting all properties.
function EditSC_A_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_A (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end





function EditSC_w1_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_w1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_w1 as text
%        str2double(get(hObject,'String')) returns contents of EditSC_w1 as a double


% --- Executes during object creation, after setting all properties.
function EditSC_w1_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_w1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditSC_B_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_B (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_B as text
%        str2double(get(hObject,'String')) returns contents of EditSC_B as a double


% --- Executes during object creation, after setting all properties.
function EditSC_B_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_B (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditSC_w2_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_w2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_w2 as text
%        str2double(get(hObject,'String')) returns contents of EditSC_w2 as a double


% --- Executes during object creation, after setting all properties.
function EditSC_w2_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_w2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditSC_w0_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_w0 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_w0 as text
%        str2double(get(hObject,'String')) returns contents of EditSC_w0 as a double


% --- Executes during object creation, after setting all properties.
function EditSC_w0_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_w0 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


% --- Executes on button press in ButtonSC.
function ButtonSC_Callback(hObject, eventdata, handles)
% hObject    handle to ButtonSC (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
SinCosSignal()




function EditSC_xb_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_xb (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_xb as text
%        str2double(get(hObject,'String')) returns contents of EditSC_xb as a double


% --- Executes during object creation, after setting all properties.
function EditSC_xb_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_xb (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditSC_xa_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_xa (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_xa as text
%        str2double(get(hObject,'String')) returns contents of EditSC_xa as a double


% --- Executes during object creation, after setting all properties.
function EditSC_xa_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_xa (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end




% --- Executes during object creation, after setting all properties.
function PanelLineSignal_CreateFcn(hObject, eventdata, handles)
% hObject    handle to PanelLineSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called




% --- Executes on slider movement.
function SliderX_Callback(hObject, eventdata, handles)
% hObject    handle to SliderX (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'Value') returns position of slider
%        get(hObject,'Min') and get(hObject,'Max') to determine range of slider
DrawAxis()

% --- Executes during object creation, after setting all properties.
function SliderX_CreateFcn(hObject, eventdata, handles)
% hObject    handle to SliderX (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: slider controls usually have a light gray background.
if isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor',[.9 .9 .9]);
end





function EditX_Callback(hObject, eventdata, handles)
% hObject    handle to EditX (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditX as text
%        str2double(get(hObject,'String')) returns contents of EditX as a double


% --- Executes during object creation, after setting all properties.
function EditX_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditX (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function EditY_Callback(hObject, eventdata, handles)
% hObject    handle to EditY (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditY as text
%        str2double(get(hObject,'String')) returns contents of EditY as a double


% --- Executes during object creation, after setting all properties.
function EditY_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditY (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


% --------------------------------------------------------------------
function DFT_Callback(hObject, eventdata, handles)
% hObject    handle to DFT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
DFT()



% --------------------------------------------------------------------
function IDFT_Callback(hObject, eventdata, handles)
% hObject    handle to IDFT (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
IDFT()







% --- Executes during object creation, after setting all properties.
function PanelSC_CreateFcn(hObject, eventdata, handles)
% hObject    handle to PanelSC (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called


% --------------------------------------------------------------------
function xcorrelation_Callback(hObject, eventdata, handles)
% hObject    handle to xcorrelation (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
xcorrelation()



% --- Executes on button press in radiobutton_rand.
function radiobutton_rand_Callback(hObject, eventdata, handles)
% hObject    handle to radiobutton_rand (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of radiobutton_rand



function EditSC_fs_Callback(hObject, eventdata, handles)
% hObject    handle to EditSC_fs (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of EditSC_fs as text
%        str2double(get(hObject,'String')) returns contents of EditSC_fs as a double


% --- Executes during object creation, after setting all properties.
function EditSC_fs_CreateFcn(hObject, eventdata, handles)
% hObject    handle to EditSC_fs (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function Edit_fm_Callback(hObject, eventdata, handles)
% hObject    handle to Edit_fm (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of Edit_fm as text
%        str2double(get(hObject,'String')) returns contents of Edit_fm as a double


% --- Executes during object creation, after setting all properties.
function Edit_fm_CreateFcn(hObject, eventdata, handles)
% hObject    handle to Edit_fm (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function Edit_dB_Callback(hObject, eventdata, handles)
% hObject    handle to Edit_dB (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of Edit_dB as text
%        str2double(get(hObject,'String')) returns contents of Edit_dB as a double


% --- Executes during object creation, after setting all properties.
function Edit_dB_CreateFcn(hObject, eventdata, handles)
% hObject    handle to Edit_dB (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


% --------------------------------------------------------------------
function UnParameter_Callback(hObject, eventdata, handles)
% hObject    handle to UnParameter (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function PNone_Callback(hObject, eventdata, handles)
% hObject    handle to PNone (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
PNone();

% --------------------------------------------------------------------
function PBoxcar_Callback(hObject, eventdata, handles)
% hObject    handle to PBoxcar (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
PBoxcar();

% --------------------------------------------------------------------
function PHamming_Callback(hObject, eventdata, handles)
% hObject    handle to PHamming (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
PHamming();

% --------------------------------------------------------------------
function PBartlett_Callback(hObject, eventdata, handles)
% hObject    handle to PBartlett (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
PBartlett();



% --------------------------------------------------------------------
function InputSignal_Callback(hObject, eventdata, handles)
% hObject    handle to InputSignal (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)




% --------------------------------------------------------------------
function classics_Callback(hObject, eventdata, handles)
% hObject    handle to classics (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function modern_Callback(hObject, eventdata, handles)
% hObject    handle to modern (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function MTM_Callback(hObject, eventdata, handles)
% hObject    handle to MTM (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
MTM();

% --------------------------------------------------------------------
function MUSIC_Callback(hObject, eventdata, handles)
% hObject    handle to MUSIC (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


% --------------------------------------------------------------------
function FeatureVector_Callback(hObject, eventdata, handles)
% hObject    handle to FeatureVector (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)




% --------------------------------------------------------------------
function StockData_Callback(hObject, eventdata, handles)
% hObject    handle to StockData (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
StockData();